﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Web;

namespace SMBCFamilyAssessment.Models
{
     [Table("Family")]
    public class Family
    {
       
        [ScaffoldColumn(false)]
        [Key]
        public int FamilyId { get; set; }
        public string Address1 { get; set; }
        [StringLength(100), Display(Name = "Address 2(Optional)")]
        public string Address2 { get; set; }
        [Required]
        [DataType(DataType.Text)]
        [StringLength(100)]
        public string Town { get; set; }
        [Required]
        [StringLength(20)]
        public string PostCode { get; set; }
        [StringLength(100), Display(Name = "Property Reference")]
        public string FamilyReference { get; set; }
        [DataType(DataType.PhoneNumber),Display(Name="Primary Phone Number")]  
        public string PrimaryPhoneNumber { get; set; }
        [StringLength(1000)]
        [DataType(DataType.MultilineText)]
        public string Notes { get; set; }
        [ScaffoldColumn(false)]
        public string CreatedBy { get; set; }
        [ScaffoldColumn(false)]
        public DateTime? CreatedDateTime { get; set; }
        [ScaffoldColumn(false)]
        public string UpdatedBy { get; set; }
        [ScaffoldColumn(false)]
        [DatabaseGenerated(DatabaseGeneratedOption.Computed)]
        public DateTime? UpdatedDateTime { get; set; }
        [DataType(DataType.DateTime)]
        public DateTime? EndedDateTime { get; set; }
        [ScaffoldColumn(false)]
        public virtual List<Person> Persons { get; set; }
        


         
 
    }
}



        